package com.ismartcoding.plain.ui.theme.palette

object MaterialYouStandard {

    // TODO: support RGB color spaces
    // calculated with error = 0.001, chroma = 100, hue in 0 until 360, hue step = 1
    val sRGBLightnessChromaMap = mapOf(
        0 to 7.62939453125E-4,
        1 to 3.5961087544759116,
        2 to 4.780750274658203,
        3 to 5.583519405788845,
        4 to 6.202197604709202,
        5 to 6.709673139784071,
        6 to 7.141865624321832,
        7 to 7.5197558932834205,
        8 to 7.855508592393663,
        9 to 8.170108795166016,
        10 to 8.478755950927734,
        11 to 8.78151363796658,
        12 to 9.078428480360243,
        13 to 9.368563758002388,
        14 to 9.65309566921658,
        15 to 9.932153489854601,
        16 to 10.205938551161024,
        17 to 10.474622514512804,
        18 to 10.737465752495659,
        19 to 10.994769202338325,
        20 to 11.247151692708334,
        21 to 11.494865417480469,
        22 to 11.737997266981337,
        23 to 11.97671890258789,
        24 to 12.211305830213758,
        25 to 12.440338134765625,
        26 to 12.664968702528212,
        27 to 12.885534498426649,
        28 to 13.102118174235025,
        29 to 13.314840528700087,
        30 to 13.523866865370008,
        31 to 13.729370964898003,
        32 to 13.93154568142361,
        33 to 14.129519992404514,
        34 to 14.323438008626303,
        35 to 14.513916439480251,
        36 to 14.701114230685764,
        37 to 14.885203043619791,
        38 to 15.066161685519749,
        39 to 15.244210561116537,
        40 to 15.419385698106554,
        41 to 15.591801537407768,
        42 to 15.761661529541016,
        43 to 15.928798251681858,
        44 to 16.091954973008896,
        45 to 16.25248803032769,
        46 to 16.410503387451172,
        47 to 16.566007402208115,
        48 to 16.71794679429796,
        49 to 16.8612183464898,
        50 to 16.995349460177952,
        51 to 17.11943096584744,
        52 to 17.233810424804688,
        53 to 17.34021716647678,
        54 to 17.43742412990994,
        55 to 17.525511847601997,
        56 to 17.586015065511067,
        57 to 17.615225050184463,
        58 to 17.616180843777126,
        59 to 17.59176466200087,
        60 to 17.543212042914497,
        61 to 17.472801208496094,
        62 to 17.381820678710938,
        63 to 17.271283467610676,
        64 to 17.14224073621962,
        65 to 16.99536853366428,
        66 to 16.831576029459637,
        67 to 16.651276482476128,
        68 to 16.45496368408203,
        69 to 16.24362309773763,
        70 to 16.024080912272137,
        71 to 15.799829694959852,
        72 to 15.570498572455513,
        73 to 15.336426628960503,
        74 to 15.097156100802952,
        75 to 14.85240724351671,
        76 to 14.601781633165148,
        77 to 14.345453050401476,
        78 to 14.08291286892361,
        79 to 13.814093271891275,
        80 to 13.538227081298828,
        81 to 13.255418141682943,
        82 to 12.964892917209202,
        83 to 12.657786475287544,
        84 to 12.30661392211914,
        85 to 11.908126407199436,
        86 to 11.460111406114367,
        87 to 10.960358513726128,
        88 to 10.406063927544487,
        89 to 9.794313642713758,
        90 to 9.12274890475803,
        91 to 8.394618564181858,
        92 to 7.635277642144097,
        93 to 6.844251420762804,
        94 to 6.025793287489149,
        95 to 5.196952819824219,
        96 to 4.350443945990668,
        97 to 3.472722371419271,
        98 to 2.5394566853841147,
        99 to 1.4974000718858507,
        100 to 7.62939453125E-4,
    )
}
